{include file="public/meat" title="编辑订单"/}
{load href="__ADMIN__/css/order.css" /}
<div class="layout cx-fex-c mt-20">
    <div class="x11 b-b pad-b10">
        <a class="button {neq name='$Request.action' value='index'}bg-blue{/neq} mr-10" href="{:url('index')}">订单速览</a>
        <a class="button {neq name='$Request.action' value='allindex'}bg-blue{/neq} mr-10" href="{:url('allindex')}">全部订单列表</a>
        <a class="button {neq name='$Request.action' value='shopindex'}bg-blue{/neq} mr-10" href="{:url('shopindex')}">产品订单列表</a>
        <a class="button {neq name='$Request.action' value='tuanindex'}bg-blue{/neq}" href="{:url('tuanindex')}">拼团订单列表</a>
    </div>
</div>
<div class="layout cx-fex-c">
    <div class="xl11">
        <fieldset class="cx-field">
            <legend class="cx-field-legend">编辑订单</legend>
            <form class="layui-form" id="addform"  role="form" action="" method="post">
                <h3 class="t-c" style="border-bottom: 1px solid #dfdfdf;font-size: 1.6rem;color: #666;line-height: 40px;">联系人信息</h3>
                <div class="cx-fex-c mb-15">
                    <div class="x3 t-r">
                        <label class="lab t-gray">微信名</label>
                    </div>
                    <div class="xs8 xl9">
                        <label class="lab">{$postdb.conf.nickname}</label>
                    </div>
                </div>
                <div class="cx-fex-c mb-15">
                    <div class="x3 t-r">
                        <label class="lab t-gray">收货人</label>
                    </div>
                    <div class="xs8 xl9">
                        <label class="lab">{$postdb.conf.adduname|default=""}</label>
                    </div>
                </div>
                <div class="cx-fex-c mb-15">
                    <div class="x3 t-r">
                        <label class="lab t-gray">联系方式</label>
                    </div>
                    <div class="xs8 xl9">
                        <label class="lab">{$postdb.conf.phone|default=""}</label>
                    </div>
                </div>
                <div class="cx-fex-c mb-15">
                    <div class="x3 t-r">
                        <label class="lab t-gray">邮编</label>
                    </div>
                    <div class="xs8 xl9">
                        <label class="lab">{$postdb.conf.postal|default=""}</label>
                    </div>
                </div>
                <div class="cx-fex-c mb-15">
                    <div class="x3 t-r">
                        <label class="lab t-gray">地址</label>
                    </div>
                    <div class="xs8 xl9">
                        <label class="lab">{$postdb.conf.addres|default=""}</label>
                    </div>
                </div>
                <div class="cx-fex-c mb-15">
                    <div class="x3 t-r">
                        <label class="lab t-gray">订单留言</label>
                    </div>
                    <div class="xs8 xl9">
                        <label class="lab">{$postdb.conf.message|default="无"}</label>
                    </div>
                </div>

                <h3 class="t-c mt-20" style="border-bottom: 1px solid #dfdfdf;font-size: 1.6rem;color: #666;line-height: 40px;">商品信息</h3>
                <div class="cx-fex-c mb-15">
                    <div class="x3 t-r">
                        <label class="lab t-gray">商品信息</label>
                    </div>
                    <div class="xs8 xl9">
                        {eq name="postdb.mid" value="100"}
                        {volist name="postdb.conf.shop" id="cx" empty="" key="k"}
                        <div class="layout cx-fex-l order-li-contcp">
                            <div class="order-li-img">
                                <img class="img-responsive" src="{$cx.picurl}" alt="{$cx.title}" >
                            </div>
                            <div class="xl9 pad-l10 cx-fex fex-column">
                                <h3 class="or-title t-14">{$cx.title}</h3>
                                <div class="layout cx-fex-l">
                                    数量: {$cx.num}
                                </div>
                            </div>
                        </div>
                        {/volist}
                        {else /}
                        <div class="layout cx-fex-l order-li-contcp">
                            <div class="order-li-img">
                                <img class="img-responsive" src="{$cx.picurl}" alt="{$cx.title}" >
                            </div>
                            <div class="xl9 pad-l10 cx-fex-c fex-items-c fex-column">
                                <h3 class="or-title t-14">{$cx.title}</h3>
                            </div>
                        </div>
                        {/eq}
                    </div>
                </div>

                <h3 class="t-c mt-20" style="border-bottom: 1px solid #dfdfdf;font-size: 1.6rem;color: #666;line-height: 40px;">订单信息</h3>
                <div class="cx-fex-c mb-15">
                    <div class="x3 t-r">
                        <label class="lab t-gray">订单编号</label>
                    </div>
                    <div class="xs8 xl9">
                        <label class="lab">{$postdb.oid}</label>
                    </div>
                </div>
                <div class="cx-fex-c mb-15">
                    <div class="x3 t-r">
                        <label class="lab t-gray">微信订单编号</label>
                    </div>
                    <div class="xs8 xl9">
                        <label class="lab">{eq name="postdb.orderplay.status" value="0"}待付款{else /}{$postdb.orderplay.status}{/eq}</label>
                    </div>
                </div>
                <div class="cx-fex-c mb-15">
                    <div class="x3 t-r">
                        <label class="lab t-gray">下单时间</label>
                    </div>
                    <div class="xs8 xl9">
                        <label class="lab">{$postdb.addtime|date="Y-m-d h:i:d",###}</label>
                    </div>
                </div>
                <div class="cx-fex-c mb-15">
                    <div class="x3 t-r">
                        <label class="lab t-gray">订单名称</label>
                    </div>
                    <div class="xs8 xl9">
                        <label class="lab">{$postdb.title}</label>
                    </div>
                </div>
                <div class="cx-fex-c mb-15">
                    <div class="x3 t-r">
                        <label class="lab t-gray">订单总金额</label>
                    </div>
                    <div class="xs8 xl9">
                        <label class="lab t-red t-16">{:number_format($postdb['allmoney'] / 100,'2')} 元</label>
                    </div>
                </div>
                <div class="cx-fex-c mb-15">
                    <div class="x3 t-r">
                        <label class="lab t-gray">订单支付金额</label>
                    </div>
                    <div class="xs8 xl9">
                        <label class="lab t-red t-16">{:number_format($postdb['pricemoney'] / 100,'2')} 元</label>
                    </div>
                </div>
                <div id="tmoney" class="cx-fex-c mb-15" {in name='postdb.playstatus' value='0,1,2,4,5'}style="display: none;"{/in}>
                    <div class="x3 t-r"><label class="lab t-gray">退款金额</label></div>
                    <div class="xs8 xl9">
                        <div class="cx-input-tabel">
                            <input name="tpricemoney" placeholder="请输入退款金额" class="ipt" value="{:number_format($postdb.conf.tuikuan / 100,'2')}" type="text" {eq name="postdb.playstatus" value="3"}disabled{/eq}>
                            <span class="cx-input-fl">元</span>
                        </div>
                    </div>
                </div>
                <div class="cx-fex-c mb-15" {in name='postdb.playstatus' value='0,1,2,4,5'}style="display: none;"{/in}>
                    <div class="x3 t-r"><label class="lab t-gray"></label></div>
                    <div class="xs8 xl9">
                        {eq name="postdb.playstatus" value="6"}
                        <button class="button bg-yellow" lay-submit lay-filter="order" data-order="2">确认退款</button>
                        {else /}
                        <span class="button bor-yellow">已退款</span>
                        {/eq}

                    </div>
                </div>
                <div class="cx-fex-c mb-15">
                    <div class="x3 t-r"><label class="lab t-gray">快递公司</label></div>
                    <div class="xs8 xl9">
                        <select name='kdname' required lay-verify="required">
                            {volist name="kuaidilist" id="cx" empty=""}
                            <option {eq name="$postdb.kdname|default=''" value="$cx.title"}selected="selected"{/eq} value="{$cx.title}">{$cx.title}</option>
                            {/volist}
                        </select>
                    </div>
                </div>
                <div class="cx-fex-c mb-15">
                    <div class="x3 t-r"><label class="lab t-gray">快递单号</label></div>
                    <div class="xs8 xl9">
                        <div>
                            <input name="kdcode" placeholder="请输入快递单号" class="ipt" value="{$postdb.kdcode|default=''}" type="text">
                        </div>
                    </div>
                </div>
                <div class="cx-fex-c mb-15">
                    <div class="x3 t-r"></div>
                    <div class="xs8 xl9">
                        <input type="hidden" name="oid" required lay-verify="required" value="{$postdb.oid}">
                        <input type="hidden" name="__token__" required lay-verify="required" value="{$Request.token}" />
                        <button class="button bg-blue" lay-submit lay-filter="order" data-order="1">确认发货</button>
                    </div>
                </div>
            </form>
        </fieldset>
    </div>
</div>
<div style="height: 20px; overflow: hidden"></div>
{include file="public/js" /}
<script>
    layui.config({
        base: '__ADMIN__/js/'
    }).use('app');

</script>
{include file="public/footer" /}